QuickTime Movie File Format Specification, May 1996

| Previous | Chapter contents | Chapter top | Next |

Color Table Atoms

Color table atoms define a list of preferred colors for displaying the movie on devices that only support 256 colors. The list may contain up to 256 colors. These optional atoms have a type value of 'ctab' . The color table atom contains a Macintosh Color Table data structure. Figure 0-8 shows the layout of a color table atom.

Figure 8 The layout of a color table atom

The color table atom contains the following data elements.

Size
A 32-bit integer that specifies the number of bytes in this color table atom.
Type
A 32-bit integer that identifies the atom type; this field must be set to 'ctab' .
Color table seed
A 32-bit integer that must be set to 0.
Color table flags
A 16-bit integer that must be set to 0x8000
Color table size
A 16-bit integer that indicates the number of colors in the following color array. This is a zero-relative value; setting this field to 0 means that there is one color in the array.
Color array
An array of colors. Each color is made up of four unsigned 16-bit integers. The first integer must be set to 0, the second is the red value, the third is the green value, and the fourth is the blue value.

© 1997 Apple Computer, Inc.

| Previous | Chapter contents | Chapter top | Next |